/**
 * Project  : Looker
 * Package  : net.freestu.looker.common
 * File     : SiteManager.java
 * Author   : solosky < solosky772@qq.com >
 * Date     : Aug 22, 2009
 * Modified : Aug 22, 2009
 * License  : Apache License 2.0 
 */
package net.freestu.looker.common;

import java.util.ArrayList;
import java.util.List;

/**
 *  站点管理
 */
public class SiteManager
{
	/**
	 * 站点列表
	 */
	private List<Site> siteList;
	
	/**
	 * 单例对象
	 */
	private static SiteManager instance;
	
	/**
	 * 构造函数
	 */
	private SiteManager()
	{
		this.siteList = new ArrayList<Site>();
	}
	
	/**
	 * 返回单例对象
	 */
	public static SiteManager getInstance()
	{
		if(instance==null)
			instance = new SiteManager();
		return instance;
	}
	
	/**
	 * 添加站点
	 */
	public void addSite(Site site)
	{
		this.siteList.add(site);
	}
	
	public List <Site> getSiteList()
	{
		return siteList;
	}
}
